import { http } from '@/utils/http/axios';
const resourcelib = '/iop-resourcelib';

// 登录
export function login(params) {
	return http.request({
		url: `${resourcelib}/manage/login`,
		method: 'POST',
		params,
	});
}
export function bookList(params) {
	return http.request({
		url: `${resourcelib}/res/book/list`,
		method: 'POST',
		params,
	});
}

export function deleteBookRow(params) {
	return http.request(
		{
			url: `${resourcelib}/res/book/delete`,
			method: 'POST',
			params,
		},
		{ isShowMessage: true, successMessageText: '删除成功' }
	);
}

export function changeRowStatus(params) {
	return http.request(
		{
			url: `${resourcelib}/res/status`,
			method: 'POST',
			params,
		},
		{ isShowMessage: true, successMessageText: '操作成功' }
	);
}
